﻿using System;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;
using Caliburn.Micro;
using System.ComponentModel.Composition;
using MEFNavigation;

namespace NavTest2.ViewModels
{

    [ExportViewModel("Home")]
    public class HomePageViewModel : Screen
    {
        
        public Home View { get; set; }

        public HomePageViewModel()
        {
            //ViewModelBinder.Bind(this, this.View, null);
        }

        string name;

        public string Name
        {
            get { return name; }
            set
            {
                name = value;
                NotifyOfPropertyChange(() => Name);
                NotifyOfPropertyChange(() => CanSayHello);
            }
        }

        public bool CanSayHello
        {
            get { return !string.IsNullOrWhiteSpace(Name); }
        }

        public void SayHello()
        {
            
            MessageBox.Show(this.Name);
        }
    }
}
